/**
 * 功能:TK_COMPANIES Service类
 * 开发人员:chengd
 * 创建时间:2012/4/21 16:44:21
 */
package com.towker.frame.service.basicData;

import org.springframework.stereotype.Service;
import com.towker.core.db.EntityDao;
import com.towker.core.db.BaseService;
import com.towker.frame.model.basicData.Companies;
import com.towker.frame.dao.basicData.CompaniesDao;

@Service
public class CompaniesService extends BaseService<Companies, java.lang.Long>
{
	private CompaniesDao dao;
	
	public void setCompaniesDao(CompaniesDao dao)
	{
		this.dao = dao;
	}

	@SuppressWarnings("unchecked")
	@Override
	protected EntityDao getEntityDao()
	{
		return this.dao;
	}

	public boolean checkExistsCode(String co_code, Integer id) {
		return dao.checkExistsCode(co_code, id);
	}
	
	public Companies getByCode(String co_code) {
		return dao.getByCode(co_code);
	}
}
